<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>packagehtml</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
	<h2>List of UGens</h2>
	
	<strong>Sound Generators</strong>
	
		<ul>
		<li>Noise</li>
		<li>Oscil</li>
		<li>LiveInput</li>
		<li>FilePlayer</li>
		<li>Sampler</li>
		<li>Vocoder</li>
		</ul>
	
	<strong>Effects</strong>
	
	<ul>
		<li>Delay</li>
		<li>Pan</li>
		<li>Balance</li>
		<li>Gain</li>
		<li>MoogFilter</li>
		<li>BitCrush</li>
		<li>WaveShaper</li>
		<li>Flanger</li>
	</ul>
	
	<strong>Envelopes</strong>
	
	<ul>
		<li>Line</li>
		<li>ADSR</li>
		<li>Damp</li>
		<li>GranulateRandom</li>
		<li>GranulateSteady</li>
	</ul>
	
	<strong>Math</strong>

	<ul>
		<li>Abs</li>
		<li>Constant</li>
		<li>Midi2Hz</li>
		<li>Multiplier</li>
		<li>Reciprocal</li>
		<li>Summer</li>
	</ul>
	
	<strong>Utility</strong>
	
	<ul>
		<li>Bypass</li>
		<li>EnvelopeFollower</li>
		<li>TickRate</li>
		<li>Sink</li>
	</ul>
	
	<p>
	AudioOutput can also be treated as a UGen for the purposes of patching, but it stands alone, different from the rest.  
	</p>
	
	<strong>Instantiating a UGen</strong>
	
	<p>
	Whenever you want to use a UGen, you'll need to instantiate it first.  
	The code to instantiate and Oscil UGen can look like this:
	</p>
	
	<code>
	Oscil osc = new Oscil( 349.23, 0.8 );
	</code>
	
	<p>
	This line tells Processing to create a new reference to an Oscil object and call that reference "osc".  
	This line also says to "instantiate" an Oscil object using one of its constructors, specifically, 
	the constructor which takes two float values.  This line also tells Processing to make the new object 
	ref "osc" and make it point to the newly instantiated Oscil object.  
	In summary, this line makes "osc" refer to a new Oscil object.  
	Every UGen will need to be instantiated in a fashion similar to this, 
	although sometimes the creation of the reference and the creation of the object may need to be put in different locations.
	</p>
			
	<strong>Inputs</strong>
	
	<p>
	Almost all UGens have inputs.  An input is a way to control what the UGen does while it's generating sound.  
	For instance, an Oscil UGen has an amplitude, frequency, and phase input.  
	The frequency input allows the frequency to be changed as the Oscil is sound.  
	Many of the UGens, like the following effects UGens, have an audio input.  
	This is what brings in the sampleframes from the previous UGens.  
	Often when directly patching to a UGen, you are actually patching to its audio input.
	</p>
	
	<strong>Sound Generators</strong>
	
	<p>
	An Oscil UGen is an oscillator.  
	It creates an output waveform which repeats at the specified frequency and at the specified amplitude.  
	In the case of Oscil, if a constructor with two floats is called, the first is read as the frequency and 
	the second is read as the amplitude.  It is possible to include a waveshape as well, as a third argument.
	</p>
	
	<p>
	The Noise UGen generates noise of different "tints": white, pink, and red/brown.
	Wikipedia has some excellent articles on audio noise.
	</p>
	
	<p>
	LiveInput transmits incoming audio through the synthesis chain.  The incoming audio is selected by the operating system.
	</p>
	
	<p>
	FilePlayer will play a file (even from the web!) into the synthesis stream.  It can be looped and paused as desired.
	</p>
	
	<p>
	Sampler is typically used to load a short audio file into memory and then "trigger" it to play the sound. 
	Before triggering the sound you can set the inputs to control the section of the sample to play, the amplitude,
	the duration of the fade in of the sound (attack), and the playback rate.
	</p>
	
	<p>
	Vocoder is a very simple vocoding effect (http://en.wikipedia.org/wiki/Vocoder) that provides an audio and a modulator input.
	</p>  
	
	<strong>Effects</strong>
	
	<p>
	The Delay UGen repeats a delayed version of the incoming signal.
	</p>
	
	<p>
	The Pan UGen takes a mono signal and specifies a stereo position for that signal.
	</p>
	
	<p>
	The Balance UGen attenuates the left or right channel of stereo signal.
	</p>
	
	<p>
	The Gain attenuates or amplifies the incoming signal.  Gain is expressed in dB.
	</p>
	
	<p>
	BitCrush reduces the bit resolution of the incoming signal.
	</p>
	
	<p>
	WaveShaper uses the incoming signal as the index to another wave.  
	This is a standard form of waveform synthesis and Wikipedia has a good article about it.
	</p>
	
	<p>
	MoogFilter is a digital model of the analog filter found on Moog synthesizers. It can be 
	configured to be either low pass, band pass, or high pass.
	</p>
	
	<p>
	Flanger is a special kind of tight delay that has modulation of the delay time built into the algorithm.
	</p>
	
	<strong>Envelopes</strong>
	
	<p>
	Envelopes are generally used to control the amplitude or another aspect of the sound during the playback of a note.  
	A more detailed discussion of the usage of envelopes will follow in the Instruments section.
	</p>
	
	<p>
	The Line Ugen outputs a value which changes from a specified beginning value to an ending value over a specified time.
	</p>
	
	<p>
	The ADSR UGen produces an attack-decay-sustain-release envelope.
	</p>
	
	<p>
	The Damp UGen produces an attack-decay envelope.
	</p>
	
	<p>
	The GranulateSteady UGen produces steady length granular-synthesis grains from the input signal.
	</p>
	
	<p>
	The GranulateRandom UGen produces random length granular-synthesis grains from the input signal.  
	At this time, the grains for both GranulateSteady and GranulateRandom have a linear fade in and out.
	</p>
	
	<p>
	The Oscil UGen can also be used as an envelope if the frequency is set so the period of the wave is about the duration of the note.
	</p>
	
	<strong>Math</strong>
	
	<p>	
	Due to our decision to use the patching mechanism to connect synthesis chains, 
	it's unfortunately not simple to do math with the sample frames being passed along the synthesis chains.  
	We had to implement math directly as UGens.
	</p>
	
	<p>
	The Constant UGen generates a constant value as a signal.
	</p>
	
	<p>
	The Summer UGen adds (sums) all incoming inputs.
	</p>
	
	<p>
	The Multiplier UGen multiplies an incoming signal by an amplitude.
	</p>
	
	<p>
	The Reciprocal UGen generates the reciprocal of the incoming signal.  
	This can be useful when, for example, building a physical modeling instrument which is based on the length of a tube.
	</p>
	
	<p>
	The Midi2Hz UGen generates the equivalent frequency in Hertz for an incoming signal given as a MIDI note number.  
	The MIDI note number does not need to be an integer.  This permits changes in pitch which are musical in nature.
	</p>
	
	<p>
	The Abs UGen outputs the absolute value of the incoming signal.
	</p>
	
	<strong>Utility</strong>
	
	<p>
	The Bypass UGen can be used to "wrap" another UGen, enabling you to route audio around it without having to unpatch 
	anything. 
	</p>
	
	<p>
	The EnvelopeFollower UGen will analyze the incoming signal and output a value that represents the strength of that signal.
	</p>
	
	<p>
	The TickRate UGen can be used to slow down or speed up the rate at which a UGen generates.
	</p>
	
	<p>
	The Sink UGen is similar to a Summer in that it can have many UGens patched to it, but it will not produce any sound,
	instead simply ticking everything that is patched to it and discarding the audio. 
	</p>
	
	@libname Minim UGens
	@indexname index_ugens
</body>
</html>